package main

import (
	"fmt"
	"my/go_draft/php"
	"strings"
)

func main() {
	str := "welcome to Shanghai"
	needle := "hai"
	str = php.AddSlashes(str, needle)
	fmt.Println(str)
	length := php.Strlen("我删掉删掉")
	fmt.Println(length)
	result := php.Mb_subStr(str, 2, -1)
	fmt.Println(result)
	fmt.Println(php.Crc32("1"))
	fmt.Println(php.Implode([]string{"aa", "bb", "cc"}, ",,,"))
	fmt.Println(php.Ucfirst("Zbdcc"))
	fmt.Println(php.Lcfirst("ASDFSFD"))
	fmt.Println(strings.TrimSpace("  sfdsadfasdfsafd "))
	fmt.Println(php.Parsestr("a=1&b=2&c=3"))
	fmt.Println(php.Str_replace("hwang", "chenyu", "hwang is in the house", 1))
	fmt.Println(php.Str_repeat("c", 10))
	fmt.Println(php.Str_pad("aa", 10, "c", "right"))
	fmt.Println(php.Str_split("qwoincndsd", 3))
	fmt.Println(php.Str_shuffle("abcdefg"))
	fmt.Println(php.Str_pos("abcdefg", "b"))
	fmt.Println(php.Strstr("hello world!", "world"))
	fmt.Println(php.Str_word_count("str&word0count stick)safe"))
}
